package org.createModel.factory.SimpleFactory;

public class SimpleCoffeeFactory {

    public Coffee createCoffee (String type) {
        Coffee coffee = null;
        if ("AmericanCoffee".equals(type)) {
            coffee = new AmericanCoffee();
        } else if ("LatteCoffee".equals(type)) {
            coffee = new LatteCoffee();
        } else {
            return coffee;
        }
        return coffee;
    }
}
